package resp

import "likeadmin/core"

// SettingDictTypeResp 字典类型返回信息
type SettingDictTypeResp struct {
	ID         uint        `json:"id" structs:"id"`                 // 主键
	DictName   string      `json:"dictName" structs:"dictName"`     // 字典名称
	DictType   string      `json:"dictType" structs:"dictType"`     // 字典类型
	DictRemark string      `json:"dictRemark" structs:"dictRemark"` // 字典备注
	DictStatus uint8       `json:"dictStatus" structs:"dictStatus"` // 字典状态
	CreateTime core.TsTime `json:"createTime" structs:"createTime"` // 创建时间
	UpdateTime core.TsTime `json:"updateTime" structs:"updateTime"` // 更新时间
}

// SettingDictDataResp 字典数据返回信息
type SettingDictDataResp struct {
	ID         uint        `json:"id" structs:"id"`                 // 主键
	TypeId     uint        `json:"typeId" structs:"typeId"`         // 类型
	Name       string      `json:"name" structs:"name"`             // 键
	Value      string      `json:"value" structs:"value"`           // 值
	Remark     string      `json:"remark" structs:"remark"`         // 备注
	Sort       uint16      `json:"sort" structs:"sort"`             // 排序
	Status     uint8       `json:"status" structs:"status"`         // 状态: [0=停用, 1=禁用]
	CreateTime core.TsTime `json:"createTime" structs:"createTime"` // 创建时间
	UpdateTime core.TsTime `json:"updateTime" structs:"updateTime"` // 更新时间
}

// NoticeSettingResp 通知设置返回信息
type NoticeSettingResp struct {
	ID           int32       `json:"id" structs:"id"`                       //
	SceneID      int32       `json:"scene_id" structs:"scene_id"`           // 场景id
	SceneName    string      `json:"scene_name" structs:"scene_name"`       // 场景名称
	SceneDesc    string      `json:"scene_desc" structs:"scene_desc"`       // 场景描述
	Recipient    int32       `json:"recipient" structs:"recipient"`         // 接收者 1-用户 2-平台
	Type         int32       `json:"type" structs:"type"`                   // 通知类型: 1-业务通知 2-验证码
	SystemNotice string      `json:"system_notice" structs:"system_notice"` // 系统通知设置
	SmsNotice    string      `json:"sms_notice" structs:"sms_notice"`       // 短信通知设置
	OaNotice     string      `json:"oa_notice" structs:"oa_notice"`         // 公众号通知设置
	MnpNotice    string      `json:"mnp_notice" structs:"mnp_notice"`       // 小程序通知设置
	Support      string      `json:"support" structs:"support"`             // 支持的发送类型 1-系统通知 2-短信通知 3-微信模板消息 4-小程序提醒
	UpdateTime   core.TsTime `json:"update_time" structs:"update_time"`     // 更新时间
}

type SmsSettingResp struct {
	Name      string `json:"name" structs:"name"`
	Alias     string `json:"alias" structs:"alias"`
	Sign      string `json:"sign" structs:"sign"`
	AppKey    string `json:"appKey" structs:"appKey"`
	AppId     string `json:"appId" structs:"appId"`
	SecretKey string `json:"secretKey" structs:"secretKey"`
	SecretId  string `json:"secretId" structs:"secretId"`
	Status    int32  `json:"status" structs:"status"`
}

type StorageSettingResp struct {
	Name      string `json:"name" structs:"name"`
	Engine    string `json:"engine" structs:"engine"`
	Describe  string `json:"describe" structs:"describe"`
	Bucket    string `json:"bucket,omitempty" structs:"bucket"`
	Endpoint  string `json:"endpoint,omitempty" structs:"endpoint"`
	AccessKey string `json:"access_key,omitempty" structs:"access_key"`
	Domain    string `json:"domain,omitempty" structs:"domain"`
	SecretKey string `json:"secret_key,omitempty" structs:"secret_key"`
	Region    string `json:"region,omitempty" structs:"region"`
	Status    int32  `json:"status,omitempty" structs:"status"`
}

type RechargeSettingResp struct {
	Status    int `json:"status" structs:"status"`
	MinAmount int `json:"min_amount" structs:"min_amount"`
}

// UserSetResp 设置用户默认头像
type UserSetResp struct {
	DefaultAvatar string `json:"default_avatar" structs:"defaultAvatar"` // 默认头像
}

type SettingLoginResp struct {
	LoginWay        []int32 `json:"loginWay" structs:"loginWay"`
	ForceBindMobile int32   `json:"forceBindMobile" structs:"forceBindMobile"`
	OpenAgreement   int32   `json:"openAgreement" structs:"openAgreement"`
	OpenOtherAuth   int32   `json:"openOtherAuth" structs:"openOtherAuth"`
	AutoLoginAuth   []int32 `json:"autoLoginAuth" structs:"autoLoginAuth"`
}

type PaySettingResp struct {
	Name        string `json:"name" structs:"name"`
	DisplayName string `json:"display_name" structs:"display_name"`
	Icon        string `json:"icon" structs:"icon"`
	Remark      string `json:"remark" structs:"remark"`
	Domain      string `json:"domain" structs:"domain"`
	Sort        int32  `json:"sort" structs:"sort"`
	Config      struct {
		ApiClientCert    string `json:"api_client_cert,omitempty" structs:"api_client_cert"`     //微信支付配置
		ApiClientKey     string `json:"api_client_key,omitempty" structs:"api_client_key"`       //微信支付配置
		InterfaceVersion string `json:"interface_version,omitempty" structs:"interface_version"` //微信支付配置
		MchId            string `json:"mch_id,omitempty" structs:"mch_id"`                       //微信支付配置
		MerchantType     string `json:"merchant_type,omitempty" structs:"merchant_type"`         //微信支付配置 支付宝配置
		PaySignKey       string `json:"pay_sign_key,omitempty" structs:"pay_sign_key"`           //微信支付配置
		AliPublicKey     string `json:"ali_public_key,omitempty" structs:"ali_public_key"`       //支付宝配置
		AppId            string `json:"app_id,omitempty" structs:"app_id"`                       //支付宝配置
		Mode             string `json:"mode,omitempty" structs:"mode"`                           //支付宝配置
		PrivateKey       string `json:"private_key,omitempty" structs:"private_key"`             //支付宝配置
	} `json:"config,omitempty" structs:"config"`
}

type PaySceneResp struct {
	Scene       string `json:"scene" structs:"scene"`
	IsDefault   int32  `json:"is_default" structs:"is_default"` // 1 默认
	Status      int32  `json:"status" structs:"status"`         // 1 开启 0 关闭
	PaymentName string `json:"payment_name" structs:"payment_name"`
	DisplayName string `json:"display_name" structs:"display_name"`
	Icon        string `json:"icon" structs:"icon"`
}

type ChannelMnpSettingResp struct {
	Name               string `json:"name" structs:"name"`
	OriginalId         string `json:"original_id" structs:"original_id"`
	QrCode             string `json:"qr_code" structs:"qr_code"`
	AppId              string `json:"app_id" structs:"app_id"`
	AppSecret          string `json:"app_secret" structs:"app_secret"`
	BusinessDomain     string `json:"business_domain,omitempty" structs:"business_domain"`
	DownloadFileDomain string `json:"download_file_domain,omitempty" structs:"download_file_domain"`
	RequestDomain      string `json:"request_domain,omitempty" structs:"request_domain"`
	SocketDomain       string `json:"socket_domain,omitempty" structs:"socket_domain"`
	TcpDomain          string `json:"tcp_domain,omitempty" structs:"tcp_domain"`
	UdpDomain          string `json:"udp_domain,omitempty" structs:"udp_domain"`
	UploadFileDomain   string `json:"upload_file_domain,omitempty" structs:"upload_file_domain"`
}

type ChannelOpenSettingResp struct {
	AppId     string `json:"app_id" structs:"app_id"`
	AppSecret string `json:"app_secret" structs:"app_secret"`
}

type ChannelOASettingResp struct {
	Name           string `json:"name" structs:"name"`
	OriginalId     string `json:"original_id" structs:"original_id"`
	QrCode         string `json:"qr_code" structs:"qr_code"`
	AppId          string `json:"app_id" structs:"app_id"`
	AppSecret      string `json:"app_secret" structs:"app_secret"`
	Url            string `json:"url,omitempty" structs:"url"`
	Token          string `json:"token,omitempty" structs:"token"`
	EncodingAesKey string `json:"encoding_aes_key,omitempty" structs:"encoding_aes_key"`
	EncryptionType int32  `json:"encryption_type" structs:"encryption_type"`
	BusinessDomain string `json:"business_domain,omitempty" structs:"business_domain"`
	JsSecureDomain string `json:"js_secure_domain,omitempty" structs:"js_secure_domain"`
	WebAuthDomain  string `json:"web_auth_domain,omitempty" structs:"web_auth_domain"`
}

type ChannelH5SettingResp struct {
	Status     int32  `json:"status" structs:"status"`
	PageStatus int32  `json:"page_status" structs:"page_status"`
	PageUrl    string `json:"page_url" structs:"page_url"`
	Url        string `json:"url" structs:"url"`
}

type ChannelOaMenuResp struct {
	Appid     string              `json:"appid" structs:"appid"`
	HasMenu   bool                `json:"has_menu" structs:"page_status"`
	Name      string              `json:"name" structs:"name"`
	PagePath  string              `json:"pagepath" structs:"pagepath"`
	Type      string              `json:"type" structs:"type"`
	Url       string              `json:"url" structs:"url"`
	SubButton []ChannelOaMenuResp `json:"sub_button" structs:"sub_button"`
}

// OfficialReplyResp 公众号的回复返回信息
type OfficialReplyResp struct {
	ID           int32       `json:"id" structs:"id"`                       // 主键
	Name         string      `json:"name" structs:"name"`                   // 规则名
	Keyword      string      `json:"keyword" structs:"keyword"`             // 关键词
	ReplyType    int32       `json:"reply_type" structs:"reply_type"`       // 回复类型: [1=关注回复 2=关键字回复, 3=默认回复]
	MatchingType int32       `json:"matching_type" structs:"matching_type"` // 匹配方式: [1=全匹配, 2=模糊匹配]
	ContentType  int32       `json:"content_type" structs:"content_type"`   // 内容类型: [1=文本]
	Content      string      `json:"content" structs:"content"`             // 内容
	Status       int32       `json:"status" structs:"status"`               // 启动状态: [1=启动, 0=关闭]
	Sort         int32       `json:"sort" structs:"sort"`                   // 排序编号
	CreatedAt    core.TsTime `json:"created_at" structs:"created_at"`       // 创建时间
	UpdatedAt    core.TsTime `json:"updated_at" structs:"updated_at"`       // 更新时间
	DeletedAt    core.TsTime `json:"deleted_at" structs:"deleted_at"`       // 删除时间
}
